n=[int(i)for i in input().split()]
a=[[1 for i in range(n[1])]for j in range(n[0])]
for i in range(n[0]):
    for j in range(n[1]):
       print("%4d"%(a[i][j]),end=' ')
    print()